<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ page isELIgnored="false" %>
<%@ include file="/include/taglibs.jsp" %>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/>
    <meta charset="utf-8"/>
    <!-- HTTP 1.1 -->
    <meta http-equiv="pragma" content="no-cache,no-store">
    <!-- HTTP 1.0 -->
    <meta http-equiv="cache-control" content="no-cache,no-store">
    <!-- Prevent caching at the proxy server -->
    <meta http-equiv="expires" content="0">
    <title>Oauth2验证平台</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0"/>
    <%@ include file="/include/base_styles.jsp" %>
    <script src="${ctx}/assets/admin/pagejs/common.js"></script>
</head>
<body class="no-skin">
<!-- 上面导航栏开始 -->
<%@ include file="/include/top.jsp" %>
<!-- 上面导航栏结束 -->
<div class="main-container" id="main-container">
    <script type="text/javascript">
        try {
            ace.settings.check('main-container', 'fixed')
        } catch (e) {
        }
        var _base = "${base}";
    </script>

    <!-- #section:basics/sidebar -->
    <div id="sidebar" class="sidebar responsive">
        <script type="text/javascript">
            try {
                ace.settings.check('sidebar', 'fixed')
            } catch (e) {
            }
        </script>
        <!-- 左边导航栏 -->
        <%@ include file="/include/left.jsp"%>
        <!-- 左边导航栏结束 -->

        <!-- #section:basics/sidebar.layout.minimize -->
        <div class="sidebar-toggle sidebar-collapse" id="sidebar-collapse">
            <i class="ace-icon fa fa-angle-double-left white" data-icon1="ace-icon fa fa-angle-double-left"
               data-icon2="ace-icon fa fa-angle-double-right" id="firstdenglu" style="background-color:#585858"></i>
        </div>
        <!-- /section:basics/sidebar.layout.minimize -->
        <script type="text/javascript">
            try {
                ace.settings.check('sidebar', 'collapsed')
            } catch (e) {
            }
        </script>
    </div>

    <!-- top2开始 -->
    <%@ include file="/include/pagecontent.jsp"%>

    <!-- top2结束 -->
    <script type="text/javascript">
        //Load content via ajax
        var back_url = [];//存放点击历史的数组
        ace.load_ajax_scripts([null], function () {
            jQuery(function ($) {
                //消息提醒的函数调用
                //间隔15秒
                var newdate = new Date();
                newdate = newdate.getTime();
                $('input, textarea').placeholder();

                $(function () {
                    $(".tooltip-primary").tooltip();
                });
                if ('enable_ajax_content' in ace) {
                    var options = {
                        content_url: function (url) {
                            //返回上页的url
                            back_url.push(document.location.href);
                            if (back_url.length > 20) {
                                back_url = back_url.slice(back_url.length - 19, back_url.length);
                            }
                            var path = document.location.href;
                            var path2 = path.split("#")[1];
                            var path3 = path.split("#")[1].split("?").length;
                            if (path3 > 1) {

                                return path.split("#")[1].split("?")[0];
//											+ ".action?"
//											+ path.split("#")[1].split("?")[1]; //+ url.replace(/\//, "=");
                            } else {
                                return path2;
                            }
                        }
                        , default_url: '#index'
                    }
                    ace.enable_ajax_content($, options)
                }
            });
            $(document).on('settings.ace.jqGrid' , function(ev, event_name, collapsed) {
                if( event_name === 'sidebar_collapsed' || event_name === 'main_container_fixed' ) {
                    setTimeout(function() {
                        $(".grid-table").jqGrid('setGridWidth',$(".grid-table").closest('[class*="col-"]').width());
                    }, 0);
                }
            });
        });
    </script>
</body>
</html>
